package com.cx.proxy;

import java.lang.reflect.Proxy;

/**
 * @Author:cxy
 * @Date:2022/1/25 21:28
 */
public class TestProxy {

    public static void main(String[] args) {


        final MapperProxy mapperProxy = new MapperProxy();
        MyMapper myMapper = (MyMapper) Proxy.newProxyInstance(TestProxy.class.getClassLoader(), new Class[]{MyMapper.class}, mapperProxy);
        System.out.println(myMapper.testProxy(1, "1"));

    }

}
